package com.reflex.utils;

import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.List;


@Component
public class SocketMappingConfig {

	// 初始化对象
	private static class SingletonSocketMappingConfig {
		static final SocketMappingConfig instance = new SocketMappingConfig();
	}

	// 获取对象
	public static SocketMappingConfig getInstance() {
		return SingletonSocketMappingConfig.instance;
	}

	private List<String> classPaths = new ArrayList<String>();


	public void init() throws ClassNotFoundException {
		// 通过反射获取对象方法
		// 从包package中获取所有的Class
		List<Class<?>> clsList = ClassUtil.getClasses("com.reflex.controller");
//		for (Class<?> aClass : clsList) {
//			System.out.println("############:  "+aClass);
//		}
		AnnotationUtil.validAnnotation(clsList);
	}

}
